package week03;

/*import java.util.Arrays;
import java.util.Scanner;

class Rectangle{
	private int width;
	private int length;
	
	public Rectangle(int width, int length) {
		this.width = width;
		this.length = length;
	}
	
	public int getPerimeter() {
		return (this.width +this.length )*2;
	}
	
	public int getArea() {
		return this.width *this.length ;
	}

	@Override
	public String toString() {
		return "Rectangle [width=" + width + ", length=" + length + "]";
	}	
	
}

class Circle {
	
	private int radius;
	
	public Circle(int radius) {
		this.radius = radius;
	}
	
	public int getPerimeter() {
		return (int) (2*Math.PI *this.radius );
	}
	
	public int getArea() {
		return (int)(Math.pow(this.radius ,2)*Math.PI) ;
	}

	@Override
	public String toString() {
		return "Circle [radius=" + radius + "]";
	}
	
}
public class Main3 {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		Rectangle rec[]=new Rectangle[2];
		Circle cir[] = new Circle[2];
		for(int i=0;i<2;i++) {
			rec[i]=new Rectangle(sc.nextInt(),sc.nextInt());
		}
		for(int j=0;j<2;j++) {
			cir[j]=new Circle(sc.nextInt());
		}
		System.out.println(rec[0].getPerimeter()+rec[1].getPerimeter()+cir[0].getPerimeter()+cir[1].getPerimeter());
		System.out.println(rec[0].getArea()+rec[1].getArea()+cir[0].getArea()+cir[1].getArea());
		System.out.println(Arrays.deepToString(rec));
		System.out.println(Arrays.deepToString(cir));
	}

}*/

